package com.section3.proxy;

import org.aspectj.lang.ProceedingJoinPoint;

public class MyAspect {
    public void before(){
        System.out.println("before");
    }
    public void after(){
        System.out.println("after");
    }
    public void afterReturn(){
        System.out.println("afterReturn");
    }
    public void afterThrowing(){
        System.out.println("afterThrowing");
    }
    public Object around(ProceedingJoinPoint point) throws Throwable{
        System.out.println("环绕通知: 切入点方法执行之前的增强业务逻辑在此执行了...");
        Object proceed = point.proceed();
        System.out.println("环绕通知: 切入点方法执行之后的增强业务逻辑在此执行了...");
        return proceed;
    }
}
